<?php
	ob_start();
	session_start();

	function __autoload($class_name) {
		include './'.$class_name . '.php';
	}
	
	$result = array();
	$status = true;	
	
	$cart = NULL;
	if(!isset($_SESSION['cart'])){
		$results['#success'] = false;
		$status = false;
	}else {
		$cart = $_SESSION['cart'];
	}
	
	if ($status){		
		$cart->setCouponCode(null);
		header("Location: shoppingcart.php");		
	} else {
		$results['#success'] = false;
	}

	echo json_encode($results);
	
	ob_end_flush();
?>